﻿using System;
using ExFlash.Records;

namespace ExFlash.Tags
{
    public class StartSoundTag : Tag
    {

        public UInt16 SoundId
        {
            get;
            private set;
        }

        public SoundInfo SoundInfo
        {
            get;
            private set;
        }

        public StartSoundTag(int len, int offset)
            : base(TagCodes.StartSound, len, offset)
        {

        }

        public override void SwfDeserialize(BinaryBitReader reader)
        {
            SoundId = reader.ReadUInt16();
            
            SoundInfo = new SoundInfo();
            SoundInfo.SwfDeserialize(reader);
        }

        public override void SwfSerialize(byte[] arr, ref int offset)
        {
            throw new NotImplementedException();
        }
    }
}
